﻿@using LessBoard.Models
@model LogModel
@{
    var gridMetric = new WebGrid(Model.LogMetricEntries);
    var gridErrors = new WebGrid(Model.LogErrorEntries);
}
<header>
    <h3 class="tabs_involved">
        Top 5 Log entries</h3>
    <ul class="tabs">
        <li><a href="#tabMetrics">Metrics</a></li>
        <li><a href="#tabErrors">Errors</a></li>
    </ul>
</header>
<div class="tab_container">
    <div id="tabMetrics" class="tab_content">
        @gridMetric.GetHtml(tableStyle: "tablesorter", columns: new[] { gridMetric.Column("Created", format: p => p.Created.ToShortDateString()), gridMetric.Column("Message"), gridMetric.Column("MetricName"), gridMetric.Column("MetricValue") })
    </div>
    <div id="tabErrors" class="tab_content">
        @gridErrors.GetHtml(tableStyle: "tablesorter", columns: new[] { gridErrors.Column("Created", format: p => p.Created.ToShortDateString()), gridErrors.Column("Severity"), gridErrors.Column("Category"), gridErrors.Column("Message") })
    </div>
</div>
